import Axios from "axios";
import store from "@/store";

const http = Axios.create({
  timeout: 50000,
});
// 请求拦截器
http.interceptors.request.use(function (config) {
  return config;
});

// 响应拦截器
http.interceptors.response.use((values) => {
  store.commit("setLoading", false);
  return values.data.data;
});

export default http;
